<?xml version='1.0' encoding='UTF-8' ?>
<!DOCTYPE html PUBLIC "-//W3C//DTD XHTML 1.0 Transitional//EN"
        "http://www.w3.org/TR/xhtml1/DTD/xhtml1-transitional.dtd">
<html xmlns="http://www.w3.org/1999/xhtml"
      xmlns:h="http://java.sun.com/jsf/html"
      xmlns:p="http://primefaces.org/ui"
      xmlns:f="http://java.sun.com/jsf/core"
      xmlns:ui="http://java.sun.com/jsf/facelets">
<h:head>
    <title>Facelet Title</title>
</h:head>
<h:body>
    <ui:composition template="General.xhtml">
        <ui:define name="title">
            <h:outputText value="用户中心"/>
        </ui:define>
        <ui:define name="content">
            <ui:include src="SendMessagePopup.xhtml"></ui:include>
            <h:panelGrid columns="3">
                <h:outputLink styleClass="topNav1"
                              value="ZoneList.jspx">
                    <h:outputText value="讨论"/>
                </h:outputLink>
                <h:outputText value=">>"/>
                <h:outputLink styleClass="topNav1"
                              value="UserCenter.jspx?id=#{userCenter.user.id}">
                    <h:outputText value="用户资料"/>
                </h:outputLink>
            </h:panelGrid>
            <p:separator/>

            <div style="width:960px;overflow: hidden;">


                <div style="width:200px;border:0px red solid;float:left;overflow: hidden;">
                    <div style="margin: 0 auto;text-align: center;width:160px;border:1px solid #cccccc;padding: 10px 10px 10px 10px;">
                        <h:outputLink target="_blank" value="UserCenter.jspx?id=#{userCenter.user.id}"
                                      styleClass="header">
                            <h:outputText value="#{userCenter.user.username}"/>
                        </h:outputLink>
                        <br/>
                        <p:graphicImage
                                value="#{userCenter.user.picUrl==''?'/resources/images/user_model.gif':userCenter.user.picUrl}"
                                style="width:120px;height:120px;margin: 10px 0px 10px 0px;"/><br/>

                        <h:panelGrid style="border:0px solid black;text-align: left;margin: 0 auto;width:90%;"
                                     columns="2" styleClass="threadColumn generalInfo">
                            <h:outputText value="性别" escape="false"></h:outputText>
                            <h:outputText value="#{userCenter.user.gender}" escape="false"></h:outputText>
                            <h:outputText value="年龄" escape="false"></h:outputText>
                            <h:outputText value="#{userCenter.user.age}" escape="false"></h:outputText>
                            <h:outputText value="积分" escape="false"></h:outputText>
                            <h:outputText value="#{userCenter.user.score}" escape="false"></h:outputText>
                            <h:outputText value="帖子" escape="false"></h:outputText>
                            <h:outputText value="#{userCenter.user.talkCount}" escape="false"></h:outputText>
                            <h:outputText value="最后登录" escape="false"></h:outputText>
                            <h:outputText value="#{userCenter.user.regTime}">
                                <f:convertDateTime pattern="yyyy-MM-dd" timeZone="GMT+8"/>
                            </h:outputText>
                            <h:outputLink value="UserCenter.jspx?id=#{userCenter.user.id}" styleClass="operation">
                                <h:outputText value="查看资料"/>
                            </h:outputLink>
                            <p:commandLink value="发送消息" action="#{clientSendMsg.begainSend(userCenter.user.id)}"
                                           rendered="#{clientSession.ifLogin}" onclick="msg1.show();"
                                           styleClass="operation"/>
                        </h:panelGrid>
                    </div>
                    <h:panelGrid style="width:160px;text-align: left;margin: 0 auto;line-height: 35px;">
                        <h:outputLink value="UserCenter.jspx?id=#{userCenter.user.id}"
                                      styleClass="operation"><h:outputText value="用户中心"/></h:outputLink>
                        <h:outputLink value="UserTalkList.jspx?id=#{userCenter.user.id}"
                                      styleClass="operation"><h:outputText value="用户发言"/></h:outputLink>
                        <h:outputLink value="ClientListMsg.jspx?id=#{userCenter.user.id}"
                                      rendered="#{userCenter.user.id==clientSession.usr.id}" styleClass="operation">
                            <h:outputText value="消息管理"/></h:outputLink>
                        <h:outputLink value="ClientListFile.jspx" rendered="#{userCenter.user.id==clientSession.usr.id}"
                                      styleClass="operation"><h:outputText value="个人文件"/></h:outputLink>
                        <h:outputLink value="UserDetail.jspx?id=#{userCenter.user.id}"
                                      rendered="#{userCenter.user.id==clientSession.usr.id}" styleClass="operation">
                            <h:outputText value="修改资料"/></h:outputLink>
                    </h:panelGrid>
                </div>
                <div style="width:720px;text-align: left;float:right;overflow: hidden;border:0px solid blue;margin-right: 30px;">
                    <ui:insert name="ucontent">
                    </ui:insert>
                </div>

                <div style="clear:both;"></div>
            </div>
        </ui:define>
    </ui:composition>

</h:body>
</html>

